﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;

namespace Himp.Erp
{
    /// <summary>
    /// 调价单
    /// </summary>
    public class PriceAdjustmentRec : FullAuditedAggregateRoot<Guid>, IMultiTenant
    {
        /// <summary>
        /// 订单编号
        /// </summary>
        public string OrderNo { get; set; }

        /// <summary>
        /// 执行日期
        /// </summary>
        public DateTime? ExecDate { get; set; }

        /// <summary>
        /// 执行完成状态
        /// </summary>
        public bool ExecFinishFlag { get; set; }

        /// <summary>
        /// 所属仓库Id
        /// </summary>
        public Guid MaterialWhseId { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string MaterialWhseCodg { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public string MaterialWhseName { get; set; }

        /// <summary>
        /// 品种数
        /// </summary>
        public int Varieties { get; set; }

        /// <summary>
        /// 采购总金额
        /// </summary>
        [Column(TypeName = "decimal(18,4)")]
        public decimal PurchaseAmt { get; set; }

        /// <summary>
        /// 零售总金额
        /// </summary>
        [Column(TypeName = "decimal(18,4)")]
        public decimal RetailAmt { get; set; }

        /// <summary>
        /// 状态
        /// </summary>
        public EnumPriceAdjustmentStatus Status { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public List<PriceAdjustmentDetl> PriceAdjustmentItems { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public Guid? TenantId { get; set; }
    }
}
